package com.ttc.group2.videochat.view;

import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import android.widget.ImageView;
import android.widget.RelativeLayout;

import com.ttc.group2.videochat.R;
import com.ttc.group2.videochat.utils.ViewUtil;

public class BottomActionBar extends RelativeLayout {
	public ImageView imgAction;
	public RelativeLayout rllayout;

	public BottomActionBar(Context context) {
		super(context);
		if (isInEditMode()) {
			return;
		}
		init();
	}

	public BottomActionBar(Context context, AttributeSet attrs) {
		super(context, attrs);
		if (isInEditMode()) {
			return;
		}
		init();
	}

	public BottomActionBar(Context context, AttributeSet attrs, int defStyleAttr) {
		super(context, attrs, defStyleAttr);
		if (isInEditMode()) {
			return;
		}
		init();
	}

	private void init() {
		rllayout = (RelativeLayout) View.inflate(getContext(),
				R.layout.custom_actionbar_bottom, this);
		imgAction = (ImageView) ViewUtil.findViewById(rllayout,
				R.id.action_icon);
	}

	public void setOnActionClick(OnClickListener listener) {
		imgAction.setOnClickListener(listener);
	}

}
